﻿@model SaleSoft.Models.ds_webmau
@{
    ViewBag.Title = "Chỉnh sửa chi tiết web mẫu";
    Layout = "~/Areas/administrator/Views/Shared/_Layout.cshtml";
}

<div class="bPageTitle">
    <div class="ptBody">
        <div class="content">
            <img src="/s.gif" alt="Account" class="pageTitleIcon" title="Account"><h1 class="pageType">
                Chi tiết<span class="titleSeparatingColon">:</span></h1>
            <h2 class="pageDescription">
                Web mẫu</h2>
            <div class="blank">
                &nbsp;</div>
        </div>
    </div>
    <div class="ptBreadcrumb">
    </div>
</div>
<div class="hotListElement">
    <div class="bPageBlock secondaryPalette">
        <div class="pbHeader">
            <table border="0" cellpadding="0" cellspacing="0">
                <tbody>
                    <tr>
                        <td class="pbTitle">
                            <img src="/s.gif" alt="" width="1" height="1" class="minWidth" title="">
                        </td>
                        <td class="pbButton">
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>
        <div class="pbBody">
            <div class="pbSubsection">
                @using (Html.BeginForm("Edit", "WebMau", FormMethod.Post)) {
                    @Html.ValidationSummary(true)
                    @Html.HiddenFor(p => p.id_webmau)
                    <table class="detailList" border="0" cellpadding="0" cellspacing="0">
                        <tr>
                            <td colspan="4">
                                <div id="head_1_ep" class="pbSubheader first tertiaryPalette">
                                    <span class="pbSubExtra"><span class="requiredLegend"><span class="requiredExampleOuter">
                                        <span class="requiredExample">&nbsp;</span></span><span class="requiredMark">*</span><span
                                            class="requiredText"> = Thông tin bắt buộc</span></span></span><h3>
                                                Thông tin web mẫu<span class="titleSeparatingColon">:</span></h3>
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td class="labelCol">
                              Tên web mẫu
                            </td>
                            <td colspan="3">
                                @Html.TextBoxFor(model => model.tenwebmau, new {
                               style = "width:400px"
                                       })
                               
                                 <div style="color:Red; text-align:left; ">@Html.ValidationMessageFor(model => model.tenwebmau)</div>
                            </td>
                        </tr>
                         <tr>
                            <td class="labelCol">
                              Giá
                            </td>
                            <td colspan="3">
                                @(Html.Telerik().CurrencyTextBoxFor(model => model.gia)
                                    .MinValue(0)
                                    .IncrementStep(10000)
                                    .Value(1500000)
                                    .HtmlAttributes(new { @style = "width:200px"})
                                    .EmptyMessage("Giá")

                                )
                               
                                 <div style="color:Red; text-align:left; ">@Html.ValidationMessageFor(model => model.tenwebmau)</div>
                            </td>
                        </tr>
                        <tr>
                            <td class="labelCol">
                              Hình ảnh
                            </td>
                            <td colspan="3">
                                 @(Html.Telerik().Upload()
                                    .Name("img")
                                    .Multiple(false)
                                )
                                 <div style="color:Red; text-align:left; ">@Html.ValidationMessageFor(model => model.urlhinh)</div>
                            </td>
                        </tr>
                        <tr>
                            <td class="labelCol">
                            </td>
                            <td colspan="3">
                                 <img title="@Model.tenwebmau" alt="@Model.tenwebmau" src="@Href("~/UploadImages/")@Model.urlhinh"/>
                            </td>
                        </tr>
                        <tr>
                            <td class="labelCol" width="150px">
                                Ablum web
                            </td>
                            <td>
                                @(Html.Telerik().ComboBox().Name("id_ablum")
                            .BindTo((SelectList)ViewBag.id_ablum)
                            .HtmlAttributes(new { @style = "width: 400px;" })
                            .AutoFill(true)
                            .Filterable(f => f.Enabled(true).FilterMode(AutoCompleteFilterMode.Contains))
                                )
                            </td>
                            <td class="labelCol" colspan="2">
                                <div style="color:Red; text-align:left; ">@Html.ValidationMessageFor(model => model.id_ablum)</div>
                            </td>
                        </tr>
                        <tr>
                            <td class="labelCol" width="150px">
                                Loại web
                            </td>
                            <td>
                                @(Html.Telerik().ComboBox().Name("id_loaiweb")
                            .BindTo((SelectList)ViewBag.id_loaiweb)
                            .HtmlAttributes(new { @style = "width: 400px;" })
                            .AutoFill(true)
                            .Filterable(f => f.Enabled(true).FilterMode(AutoCompleteFilterMode.Contains))
                                )
                            </td>
                            <td class="labelCol" colspan="2">
                                <div style="color:Red; text-align:left; ">@Html.ValidationMessageFor(model => model.id_loaiweb)</div>
                            </td>
                        </tr>
                        <tr>
                            <td class="labelCol" width="150px">
                                Trạng thái
                            </td>
                            <td>
                                @(Html.Telerik().DropDownList().Name("id_trangthai")
                                    .BindTo((SelectList)ViewBag.id_trangthai)
                                    .HtmlAttributes(new { @style = "width: 200px;" })
                                )
                            </td>
                            <td class="labelCol" colspan="2">
                                <div style="color:Red; text-align:left; ">@Html.ValidationMessageFor(model => model.id_trangthai)</div>
                            </td>
                        </tr>
                        <tr>
                            <td class="labelCol">
                              Mô tả
                            </td>
                            <td colspan="3">
                                @Html.TextAreaFor(model => model.mota, new
                           {
                               style = "width:200px, height:100px"
                           })
                           <script type="text/javascript">
                               CKEDITOR.replace('mota',
                                {
                                    height: '200px'
                                });
                                </script>
                                 <div style="color:Red; text-align:left; ">@Html.ValidationMessageFor(model => model.mota)</div>
                            </td>
                        </tr>
                        <tr>
                            <td>
                            </td>
                            <td colspan="2" style="text-align: left;">
                                &nbsp;<br />
                                <input class="btn" style="width: 100px" name="btnSave" value="Lưu" type="submit" />
                                @Html.ActionLink("Hủy", "index", null, new {
                                       @class = "btn",
                                       style = "width:100px"
                                   })<br />
                                &nbsp;
                            </td>
                            <td width="200px">
                            </td>
                        </tr>
                    </table>
                }
            </div>
            <div class="pbFooter secondaryPalette">
                <div class="bg">
                </div>
            </div>
        </div>
    </div>
</div>